package net.cathackers.devel.scmp.chat.interfaces;

import net.cathackers.devel.scmp.chat.impl.xmpp.iqcomponent.interfaces.Processor;

/**
 * Runner interface that loops over a queue and calls process() in a processor
 * 
 * @author UnLimited
 * 
 * @param <T>
 *            the type of the element passed to process()
 */
public interface Runner<T> {

    public boolean isRunning();

    public boolean setProcessor(Processor<T> processor);

    public Processor<T> getProcessor();

    public void setMaxPoolSize(int max);

    public void setKeepAliveTime(long time);

    public long getCompletedTaskcount();

    public long getscheduledTaskCount();

    public void stop();
}
